<?php
return array(
	'attributeLabels' => array(
		'worker.worker_name' => '用户'
	),

	'rules' => array(
		array('fatid, worker_id,account','required'),
	),
	
	'relations' => array(
		'accountType' => array(ActiveRecord::BELONGS_TO, 'FinancialAccountType', 'fatid'),
		'worker' => array(ActiveRecord::BELONGS_TO, 'WorkerAccount', 'worker_id')
	),
	'behaviors' => array(
		'uidResolver' => array(
			'class' => 'application.behaviors.LyAutoIdBehavior',
			'uid' => 'worker_id'
		),
		'userScope' => array(
			'class' => 'coms.behaviors.userScopes.DefaultScope',
			'relatedFields' => array(
				'worker_id',
			),
			'autoRun' => false,
		),
	),
	
	'_import' => array(
		array('*', 'models.ActiveRecord//*'),
	),
);